require('reflect-metadata');

import { NestFactory } from '@nestjs/core';
import { AppModule } from './app.module';
import * as cors from 'cors';

async function bootstrap() {
  const app = await NestFactory.create(AppModule);
  app.use(
    cors({
      // origin: 'http://www.zqd.com',
      origin: ['http://www.zqd.com'],
      credentials: true,
      methods: ['OPTIONS', 'GET', 'HEAD', 'PUT', 'PATCH', 'POST', 'DELETE'],
    }),
  );
  await app.listen(3000);
}
bootstrap();
